3.268 \(\int \cot ^4(c+d x) (a+b \sec (c+d x)) \, dx\)

Optimal. Leaf size=55 \[ -\frac {\cot ^3(c+d x) (a+b \sec (c+d x))}{3 d}+\frac {\cot (c+d x) (3 a+2 b \sec (c+d x))}{3 d}+a x \]

[Out]

a*x-1/3*cot(d*x+c)^3*(a+b*sec(d*x+c))/d+1/3*cot(d*x+c)*(3*a+2*b*sec(d*x+c))/d

________________________________________________________________________________________

Rubi [A]  time = 0.05, antiderivative size = 55, normalized size of antiderivative = 1.00, number of steps used = 3, number of rules used = 2, integrand size = 19, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.105, Rules used = {3882, 8} \[ -\frac {\cot ^3(c+d x) (a+b \sec (c+d x))}{3 d}+\frac {\cot (c+d x) (3 a+2 b \sec (c+d x))}{3 d}+a x \]

Antiderivative was successfully verified.

[In]

Int[Cot[c + d*x]^4*(a + b*Sec[c + d*x]),x]

[Out]

a*x - (Cot[c + d*x]^3*(a + b*Sec[c + d*x]))/(3*d) + (Cot[c + d*x]*(3*a + 2*b*Sec[c + d*x]))/(3*d)

Rule 8

Int[a_, x_Symbol] :> Simp[a*x, x] /; FreeQ[a, x]

Rule 3882

Int[(cot[(c_.) + (d_.)*(x_)]*(e_.))^(m_)*(csc[(c_.) + (d_.)*(x_)]*(b_.) + (a_)), x_Symbol] :> -Simp[((e*Cot[c
+ d*x])^(m + 1)*(a + b*Csc[c + d*x]))/(d*e*(m + 1)), x] - Dist[1/(e^2*(m + 1)), Int[(e*Cot[c + d*x])^(m + 2)*(
a*(m + 1) + b*(m + 2)*Csc[c + d*x]), x], x] /; FreeQ[{a, b, c, d, e}, x] && LtQ[m, -1]

Rubi steps

\begin {align*} \int \cot ^4(c+d x) (a+b \sec (c+d x)) \, dx &=-\frac {\cot ^3(c+d x) (a+b \sec (c+d x))}{3 d}+\frac {1}{3} \int \cot ^2(c+d x) (-3 a-2 b \sec (c+d x)) \, dx\\ &=-\frac {\cot ^3(c+d x) (a+b \sec (c+d x))}{3 d}+\frac {\cot (c+d x) (3 a+2 b \sec (c+d x))}{3 d}+\frac {1}{3} \int 3 a \, dx\\ &=a x-\frac {\cot ^3(c+d x) (a+b \sec (c+d x))}{3 d}+\frac {\cot (c+d x) (3 a+2 b \sec (c+d x))}{3 d}\\ \end {align*}

________________________________________________________________________________________

Mathematica [C]  time = 0.03, size = 62, normalized size = 1.13 \[ -\frac {a \cot ^3(c+d x) \, _2F_1\left (-\frac {3}{2},1;-\frac {1}{2};-\tan ^2(c+d x)\right )}{3 d}-\frac {b \csc ^3(c+d x)}{3 d}+\frac {b \csc (c+d x)}{d} \]

Antiderivative was successfully verified.

[In]

Integrate[Cot[c + d*x]^4*(a + b*Sec[c + d*x]),x]

[Out]

(b*Csc[c + d*x])/d - (b*Csc[c + d*x]^3)/(3*d) - (a*Cot[c + d*x]^3*Hypergeometric2F1[-3/2, 1, -1/2, -Tan[c + d*
x]^2])/(3*d)

________________________________________________________________________________________

fricas [A]  time = 0.51, size = 87, normalized size = 1.58 \[ \frac {4 \, a \cos \left (d x + c\right )^{3} + 3 \, b \cos \left (d x + c\right )^{2} - 3 \, a \cos \left (d x + c\right ) + 3 \, {\left (a d x \cos \left (d x + c\right )^{2} - a d x\right )} \sin \left (d x + c\right ) - 2 \, b}{3 \, {\left (d \cos \left (d x + c\right )^{2} - d\right )} \sin \left (d x + c\right )} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(cot(d*x+c)^4*(a+b*sec(d*x+c)),x, algorithm="fricas")

[Out]

1/3*(4*a*cos(d*x + c)^3 + 3*b*cos(d*x + c)^2 - 3*a*cos(d*x + c) + 3*(a*d*x*cos(d*x + c)^2 - a*d*x)*sin(d*x + c
) - 2*b)/((d*cos(d*x + c)^2 - d)*sin(d*x + c))

________________________________________________________________________________________

giac [B]  time = 0.26, size = 112, normalized size = 2.04 \[ \frac {a \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{3} - b \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{3} + 24 \, {\left (d x + c\right )} a - 15 \, a \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right ) + 9 \, b \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right ) + \frac {15 \, a \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{2} + 9 \, b \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{2} - a - b}{\tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{3}}}{24 \, d} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(cot(d*x+c)^4*(a+b*sec(d*x+c)),x, algorithm="giac")

[Out]

1/24*(a*tan(1/2*d*x + 1/2*c)^3 - b*tan(1/2*d*x + 1/2*c)^3 + 24*(d*x + c)*a - 15*a*tan(1/2*d*x + 1/2*c) + 9*b*t
an(1/2*d*x + 1/2*c) + (15*a*tan(1/2*d*x + 1/2*c)^2 + 9*b*tan(1/2*d*x + 1/2*c)^2 - a - b)/tan(1/2*d*x + 1/2*c)^
3)/d

________________________________________________________________________________________

maple [A]  time = 0.81, size = 86, normalized size = 1.56 \[ \frac {a \left (-\frac {\left (\cot ^{3}\left (d x +c \right )\right )}{3}+\cot \left (d x +c \right )+d x +c \right )+b \left (-\frac {\cos ^{4}\left (d x +c \right )}{3 \sin \left (d x +c \right )^{3}}+\frac {\cos ^{4}\left (d x +c \right )}{3 \sin \left (d x +c \right )}+\frac {\left (2+\cos ^{2}\left (d x +c \right )\right ) \sin \left (d x +c \right )}{3}\right )}{d} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

int(cot(d*x+c)^4*(a+b*sec(d*x+c)),x)

[Out]

1/d*(a*(-1/3*cot(d*x+c)^3+cot(d*x+c)+d*x+c)+b*(-1/3/sin(d*x+c)^3*cos(d*x+c)^4+1/3/sin(d*x+c)*cos(d*x+c)^4+1/3*
(2+cos(d*x+c)^2)*sin(d*x+c)))

________________________________________________________________________________________

maxima [A]  time = 0.57, size = 59, normalized size = 1.07 \[ \frac {{\left (3 \, d x + 3 \, c + \frac {3 \, \tan \left (d x + c\right )^{2} - 1}{\tan \left (d x + c\right )^{3}}\right )} a + \frac {{\left (3 \, \sin \left (d x + c\right )^{2} - 1\right )} b}{\sin \left (d x + c\right )^{3}}}{3 \, d} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(cot(d*x+c)^4*(a+b*sec(d*x+c)),x, algorithm="maxima")

[Out]

1/3*((3*d*x + 3*c + (3*tan(d*x + c)^2 - 1)/tan(d*x + c)^3)*a + (3*sin(d*x + c)^2 - 1)*b/sin(d*x + c)^3)/d

________________________________________________________________________________________

mupad [B]  time = 1.56, size = 90, normalized size = 1.64 \[ a\,x+\frac {{\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}^3\,\left (\frac {a}{24}-\frac {b}{24}\right )}{d}-\frac {{\mathrm {cot}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}^3\,\left (\left (-5\,a-3\,b\right )\,{\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}^2+\frac {a}{3}+\frac {b}{3}\right )}{8\,d}-\frac {\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )\,\left (\frac {5\,a}{8}-\frac {3\,b}{8}\right )}{d} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

int(cot(c + d*x)^4*(a + b/cos(c + d*x)),x)

[Out]

a*x + (tan(c/2 + (d*x)/2)^3*(a/24 - b/24))/d - (cot(c/2 + (d*x)/2)^3*(a/3 + b/3 - tan(c/2 + (d*x)/2)^2*(5*a +
3*b)))/(8*d) - (tan(c/2 + (d*x)/2)*((5*a)/8 - (3*b)/8))/d

________________________________________________________________________________________

sympy [F]  time = 0.00, size = 0, normalized size = 0.00 \[ \int \left (a + b \sec {\left (c + d x \right )}\right ) \cot ^{4}{\left (c + d x \right )}\, dx \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(cot(d*x+c)**4*(a+b*sec(d*x+c)),x)

[Out]

Integral((a + b*sec(c + d*x))*cot(c + d*x)**4, x)

________________________________________________________________________________________